﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Gameroom.aspx.cs" Inherits="_2011DBProject.Gameroom" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<link rel=StyleSheet HREF='design1.css' type='text/css'>
<html xmlns="http://www.w3.org/1999/xhtml" >
<head id="Head1" runat="server">
<title>새벽 골프</title>
 </head>
<body>
<form id="form1" runat="server">
<div>
<p align = "left">
<asp:Button ID="btnGoLogout" runat="server" onclick="btnGoLogout_onclick"
 Text="☜ 로 그 아 웃" Width="150px" />
<asp:Button ID="btnGoServer" runat="server" onclick="btnGoServer_onclick"
 Text="☜ 서 버 선 택" Width="150px" />
<asp:Button ID="btnGoCharacter" runat="server" onclick="btnGoCharacter_onclick"
 Text="☜ 캐 릭 선 택" Width="150px" />
<asp:Button ID="btnGoChannel" runat="server" onclick="btnGoChannel_onclick"
 Text="☜ 채 널 선 택" Width="150px" />
</p>
<asp:Label ID="lblServer" runat="server" Font-Bold="True" Font-Size="Large"
 ForeColor="#FFFF99" Text="이름없음"></asp:Label>
&nbsp;서버의
<asp:Label ID="lblChannel" runat="server" Font-Bold="True" Font-Size="Large"
 ForeColor="#FFFF99" Text="이름없음"></asp:Label>
&nbsp;채널 메인화면<br />
<br />
<table width="960" border="1" align="center">
<tr>
<td width="50%"><font color="white" size="5px">게임방 리스트</font>
<asp:Label ID="lblHid" runat="server" Text="Label" Visible="False"></asp:Label>
<br />
<br />
<asp:Button ID="btnEnterRoom" runat="server" onclick="btnEnterRoom_Click"
 Text="방 입장하기" Width="400px" Visible="false" Height="40px" />
<br />
<asp:GridView ID="gvGameRoom" runat="server" AutoGenerateColumns="False"
 CellPadding="4" DataKeyNames="GAMEROOM_NO"
 DataSourceID="sqldsGameRoom" EmptyDataText="표시할 데이터 레코드가 없습니다." AllowPaging="True" onselectedindexchanged="gvGameRoom_SelectedIndexChanged"
 HorizontalAlign="Center" Width="430px" ForeColor="#333333"
 GridLines="None">
<RowStyle BackColor="#EFF3FB" />
<Columns>
<asp:CommandField
 ShowSelectButton="True" HeaderText="입장" SelectText="입장" />
<asp:BoundField DataField="GAMEROOM_NO" HeaderText="방번호"
 ReadOnly="True" SortExpression="GAMEROOM_NO" />
<asp:BoundField DataField="GAMEROOM_NAME" HeaderText="게임방 이름"
 SortExpression="GAMEROOM_NAME" />
<asp:BoundField DataField="GAME_TYPE" HeaderText="경기 규칙"
 SortExpression="GAME_TYPE" />
<asp:BoundField DataField="PARTICIPANT_QTY" HeaderText="제한 인원"
 SortExpression="PARTICIPANT_QTY" />
<asp:BoundField DataField="MIN_LEVEL" HeaderText="최소 레벨"
 SortExpression="MIN_LEVEL" />
</Columns>
<FooterStyle BackColor="#507CD1" ForeColor="White" Font-Bold="True" />
<PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
<EmptyDataTemplate>
<br />
<font size="3px" color="#ffff99">개설된 방이 없습니다.</font>
<br />
</EmptyDataTemplate>
<SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
<HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<EditRowStyle BackColor="#2461BF" />
<AlternatingRowStyle BackColor="White" />
</asp:GridView>
<asp:SqlDataSource ID="sqldsGameRoom" runat="server"
 ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
 DeleteCommand="DELETE FROM &quot;GAMEROOM&quot; WHERE &quot;CHANNEL_NO&quot; = :CHANNEL_NO AND &quot;GAMEROOM_NO&quot; = :GAMEROOM_NO AND &quot;SERVER_NO&quot; = :SERVER_NO"
 InsertCommand="INSERT INTO &quot;GAMEROOM&quot; (&quot;CHANNEL_NO&quot;, &quot;GAME_TYPE&quot;, &quot;PARTICIPANT_QTY&quot;, &quot;HOLE_QTY&quot;, &quot;MIN_LEVEL&quot;, &quot;PASSWORD&quot;, &quot;GAMEROOM_NAME&quot;, &quot;GAMEROOM_NO&quot;, &quot;SERVER_NO&quot;, &quot;COURSE_NO&quot;) VALUES (:CHANNEL_NO, :GAME_TYPE, :PARTICIPANT_QTY, :HOLE_QTY, :MIN_LEVEL, :PASSWORD, :GAMEROOM_NAME, :GAMEROOM_NO, :SERVER_NO, :COURSE_NO)"
 ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>"
 SelectCommand="SELECT &quot;CHANNEL_NO&quot;, &quot;GAME_TYPE&quot;, &quot;PARTICIPANT_QTY&quot;, &quot;HOLE_QTY&quot;, &quot;MIN_LEVEL&quot;, &quot;PASSWORD&quot;, &quot;GAMEROOM_NAME&quot;, &quot;GAMEROOM_NO&quot;, &quot;SERVER_NO&quot;, &quot;COURSE_NO&quot; FROM &quot;GAMEROOM&quot; WHERE ((&quot;CHANNEL_NO&quot; = :CHANNEL_NO) AND (&quot;SERVER_NO&quot; = :SERVER_NO)) and GAMEROOM_NO != 0"
 UpdateCommand="UPDATE &quot;GAMEROOM&quot; SET &quot;GAME_TYPE&quot; = :GAME_TYPE, &quot;PARTICIPANT_QTY&quot; = :PARTICIPANT_QTY, &quot;HOLE_QTY&quot; = :HOLE_QTY, &quot;MIN_LEVEL&quot; = :MIN_LEVEL, &quot;PASSWORD&quot; = :PASSWORD, &quot;GAMEROOM_NAME&quot; = :GAMEROOM_NAME, &quot;COURSE_NO&quot; = :COURSE_NO WHERE &quot;CHANNEL_NO&quot; = :CHANNEL_NO AND &quot;GAMEROOM_NO&quot; = :GAMEROOM_NO AND &quot;SERVER_NO&quot; = :SERVER_NO">
<SelectParameters>
<asp:SessionParameter DefaultValue="" Name="CHANNEL_NO" SessionField="Ch"
 Type="Decimal" />
<asp:SessionParameter DefaultValue="NULL" Name="SERVER_NO"
 SessionField="SERVER" Type="Decimal" />
</SelectParameters>
<DeleteParameters>
<asp:Parameter Name="CHANNEL_NO" Type="Decimal" />
<asp:Parameter Name="GAMEROOM_NO" Type="Decimal" />
<asp:Parameter Name="SERVER_NO" Type="Decimal" />
</DeleteParameters>
<UpdateParameters>
<asp:Parameter Name="GAME_TYPE" Type="String" />
<asp:Parameter Name="PARTICIPANT_QTY" Type="Decimal" />
<asp:Parameter Name="HOLE_QTY" Type="Decimal" />
<asp:Parameter Name="MIN_LEVEL" Type="Decimal" />
<asp:Parameter Name="PASSWORD" Type="String" />
<asp:Parameter Name="GAMEROOM_NAME" Type="String" />
<asp:Parameter Name="COURSE_NO" Type="Decimal" />
<asp:Parameter Name="CHANNEL_NO" Type="Decimal" />
<asp:Parameter Name="GAMEROOM_NO" Type="Decimal" />
<asp:Parameter Name="SERVER_NO" Type="Decimal" />
</UpdateParameters>
<InsertParameters>
<asp:Parameter Name="CHANNEL_NO" Type="Decimal" />
<asp:Parameter Name="GAME_TYPE" Type="String" />
<asp:Parameter Name="PARTICIPANT_QTY" Type="Decimal" />
<asp:Parameter Name="HOLE_QTY" Type="Decimal" />
<asp:Parameter Name="MIN_LEVEL" Type="Decimal" />
<asp:Parameter Name="PASSWORD" Type="String" />
<asp:Parameter Name="GAMEROOM_NAME" Type="String" />
<asp:Parameter Name="GAMEROOM_NO" Type="Decimal" />
<asp:Parameter Name="SERVER_NO" Type="Decimal" />
<asp:Parameter Name="COURSE_NO" Type="Decimal" />
</InsertParameters>
</asp:SqlDataSource>
<br />
<asp:Button ID="btnMakeRoom" runat="server"
 Text="방 만들기" onclick="btnMakeRoom_Click" Height="37px" Width="400px" />
</td>
<td width="240">
<asp:SqlDataSource ID="SqlDataSource1" runat="server"
 ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
 ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>"
 
        
        SelectCommand="SELECT *
FROM CHARACTER C, TITLE_BENEFIT T
WHERE C.SERVER_NO = :SERVER_NO AND C.CHARACTER_NAME = :CHARACTER_NAME and C.TITLE_NO = T.TITLE_NO">
<SelectParameters>
<asp:SessionParameter Name="SERVER_NO" SessionField="SERVER" Type="Decimal" />
<asp:SessionParameter Name="CHARACTER_NAME" SessionField="CHARACTER_NAME"
 Type="String" />
</SelectParameters>
</asp:SqlDataSource>
<asp:ImageButton ID="ImageButton1" runat="server" Height="200px"
 Width="150px" onclick="ImageButton1_Click" />
</td>
<td colspan="2">

<asp:Label ID="lblCharacterName" runat="server" Text="Label" Font-Size="X-Large" 
        ForeColor="#FFFF66"></asp:Label>
<br />&nbsp;&nbsp;
<br />
<asp:Label ID="Label6" runat="server" Text="레벨:"></asp:Label>
&nbsp;<asp:Label ID="lblLevel" runat="server" Text="Label"></asp:Label><br />
<asp:Label ID="Label7" runat="server" Text="엔지: "></asp:Label>
<asp:Label ID="lblEnge" runat="server" Text="Label"></asp:Label>
    <br />
<asp:Label ID="Label10" runat="server" Text="남은경험치: "></asp:Label>
<asp:Label ID="lblExp" runat="server" Text="Label"></asp:Label>
    <br />
<asp:Label ID="Label11" runat="server" Text="모델: "></asp:Label>
<asp:Label ID="lblModel" runat="server" Text="Label"></asp:Label><br />
<br />
</td>
</tr>
<tr>
<td>
<font color="white" size="5px">대 화 창</font><br />
<br />
<asp:GridView ID="gvConversationChGuild" runat="server"
 AutoGenerateColumns="False" CellPadding="4"
 DataSourceID="sqldsConversationChGuild" EmptyDataText="표시할 데이터 레코드가 없습니다."
 ForeColor="#333333" GridLines="None" AllowPaging="True" Visible="False" HorizontalAlign="Center">
<RowStyle BackColor="#EFF3FB" />
<Columns>
<asp:BoundField DataField="CHARACTER_NAME"
 SortExpression="CHARACTER_NAME" HeaderStyle-Width="100"
 HeaderText="CHARACTER_NAME" >
</asp:BoundField>
<asp:BoundField DataField="CONTENT"
 SortExpression="CONTENT"
HeaderStyle-Width="260" HeaderText="CONTENT" >
</asp:BoundField>
<asp:BoundField DataField="CONVERSATION_DATETIME"
 SortExpression="CONVERSATION_DATETIME"
 HeaderText="CONVERSATION_DATETIME" />
    <asp:BoundField DataField="CHANNEL_GUILD_CAT" HeaderText="CHANNEL_GUILD_CAT" 
        SortExpression="CHANNEL_GUILD_CAT" Visible="False" />
</Columns>
<FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
<EmptyDataTemplate>
<br /><font color="#ffff99">
<br />대화 내용이 없습니다.</font>
</EmptyDataTemplate>
<SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
<HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<EditRowStyle BackColor="#2461BF" />
<AlternatingRowStyle BackColor="White" />
</asp:GridView>
<br />
<asp:GridView ID="gvConversationCh" runat="server"
 AutoGenerateColumns="False" CellPadding="4"
 DataSourceID="sqldsConversationCh" EmptyDataText="표시할 데이터 레코드가 없습니다."
 ForeColor="#333333" GridLines="None" AllowPaging="True" HorizontalAlign="Center">
<RowStyle BackColor="#EFF3FB" HorizontalAlign="Center" />
<Columns>
<asp:BoundField DataField="CHARACTER_NAME"
 SortExpression="CHARACTER_NAME" HeaderStyle-Width="100"
 HeaderText="CHARACTER_NAME" >
</asp:BoundField>
<asp:BoundField DataField="CONTENT"
 SortExpression="CONTENT"
HeaderStyle-Width="260" HeaderText="CONTENT" >
</asp:BoundField>
<asp:BoundField DataField="CONVERSATION_DATETIME"
 SortExpression="CONVERSATION_DATETIME"
 HeaderText="CONVERSATION_DATETIME" />
    <asp:BoundField DataField="CHANNEL_GUILD_CAT" HeaderText="CHANNEL_GUILD_CAT" 
        SortExpression="CHANNEL_GUILD_CAT" Visible="False" />
</Columns>
<FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
<EmptyDataTemplate>
<br /><font color="#ffff99">대화 내용이 없습니다.</fon
<br />
</EmptyDataTemplate>
<SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
<HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<EditRowStyle BackColor="#2461BF" />
<AlternatingRowStyle BackColor="White" />
</asp:GridView>
<asp:SqlDataSource ID="sqldsConversationCh" runat="server"
 ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
 ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>"
 
        SelectCommand="SELECT CHARACTER_NAME, CONTENT, CONVERSATION_DATETIME, CHANNEL_GUILD_CAT FROM CONVERSATION WHERE (CHANNEL_NO = :CHANNEL_NO) AND (SERVER_NO = :SERVER_NO) AND (GAMEROOM_NO = 0) AND (CHANNEL_GUILD_CAT IS NULL OR CHANNEL_GUILD_CAT = ' ') ORDER BY CONVERSATION_DATETIME DESC">
<SelectParameters>
<asp:SessionParameter Name="CHANNEL_NO"
 SessionField="Ch" Type="Decimal" />
<asp:SessionParameter Name="SERVER_NO" SessionField="SERVER" Type="Decimal" />
</SelectParameters>
</asp:SqlDataSource>
<asp:SqlDataSource ID="sqldsConversationChGuild" runat="server"
 ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
 ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>"
 
        SelectCommand="SELECT CHARACTER_NAME, CONTENT, CONVERSATION_DATETIME, CHANNEL_GUILD_CAT FROM CONVERSATION WHERE (CHANNEL_NO = :CHANNEL_NO) AND (SERVER_NO = :SERVER_NO) AND (GAMEROOM_NO = 0) AND (CHANNEL_GUILD_CAT = :GUILD_NAME) ORDER BY CONVERSATION_DATETIME DESC">
<SelectParameters>
<asp:SessionParameter Name="CHANNEL_NO"
 SessionField="Ch" Type="Decimal" />
<asp:SessionParameter Name="SERVER_NO" SessionField="SERVER" Type="Decimal" />
    <asp:ControlParameter ControlID="lblGuild" DefaultValue="null" 
        Name="GUILD_NAME" PropertyName="Text" />
</SelectParameters>
</asp:SqlDataSource>
    <br />
    길드명:
    <asp:Label ID="lblGuild" runat="server" Text="Label" Visible="False"></asp:Label>
&nbsp;<asp:CheckBox ID="chkGuildChat" runat="server" AutoPostBack="True" 
        oncheckedchanged="chkGuildChat_CheckedChanged" Text="길드대화" />
    <br />
<br />
<asp:Panel ID="Panel1" runat="server" DefaultButton="btnChat">
 <asp:Label ID="Label8" runat="server" Text="대화"></asp:Label>
&nbsp;<asp:TextBox ID="txtChat" runat="server" Width="319px"></asp:TextBox><asp:Button ID="btnChat" runat="server" onclick="btnChat_Click" Text="대화하기" />
</asp:Panel>
 <br />
</td>
<td colspan="2">
    <asp:DataList ID="DataListCharacter" runat="server" DataKeyField="CHARACTER_NAME"
 DataSourceID="SqlDataSource1" Height="10px" RepeatColumns="3"
 ShowFooter="False" ShowHeader="False" Visible="False"
 Width="200px" style="margin-bottom: 15px" ItemStyle-HorizontalAlign="Right" 
        HorizontalAlign="Center">
<ItemTemplate>
&nbsp;
<asp:Label ID="CHARACTER_NAMELabel" runat="server" Text='<%# Eval("CHARACTER_NAME") %>' Visible="FALSE" />
<br />
기술:
<asp:Label ID="TECHNIQUELabel" runat="server" Text='<%# Eval("TECHNIQUE") %>' />
<br />
파워:
<asp:Label ID="POWERLabel" runat="server" Text='<%# Eval("POWER") %>' />
<br />
임팩트:
<asp:Label ID="IMPACTLabel" runat="server" Text='<%# Eval("IMPACT") %>' />
<br />
    체력:
<asp:Label ID="STRENGTHLabel" runat="server" Text='<%# Eval("STRENGTH") %>' />
<asp:Label ID="LVLLabel" runat="server" Text='<%# Eval("LVL") %>' Visible="FALSE" />
<asp:Label ID="SEXLabel" runat="server" Text='<%# Eval("SEX") %>' Visible="FALSE" />
<br />
<asp:Label ID="HADICAPLabel" runat="server" Text='<%# Eval("HADICAP") %>' Visible="false" />
<br />
피도로:
<asp:Label ID="TIREDNESSLabel" runat="server" Text='<%# Eval("TIREDNESS") %>' />
<br />
<asp:Label ID="EXP_TO_NEXT_LEVELLabel" runat="server"
 Text='<%# Eval("EXP_TO_NEXT_LEVEL") %>' Visible="false" />
<br />
평균 샷:
<asp:Label ID="AVG_SHOTSLabel" runat="server" Text='<%# Eval("AVG_SHOTS") %>' />
<br />
평균 퍼팅수:
<asp:Label ID="AVG_PUTSLabel" runat="server" Text='<%# Eval("AVG_PUTS") %>' />
<br />
<asp:Label ID="RECENT_AVG_HANDILabel" runat="server"
 Text='<%# Eval("RECENT_AVG_HANDI") %>' Visible="false" />
<br />
홀인원 횟수:
<asp:Label ID="HOLE_IN_ONE_QTYLabel" runat="server"
 Text='<%# Eval("HOLE_IN_ONE_QTY") %>' />
<br />
최대 비거리:
<asp:Label ID="MAX_DISTANCELabel" runat="server"
 Text='<%# Eval("MAX_DISTANCE") %>' />
<br />
<asp:Label ID="NG_AMOUNTLabel" runat="server" Text='<%# Eval("NG_AMOUNT") %>' Visible="FALSE" />
최대 인벤토리 수량:
<asp:Label ID="MAX_INVENTORY_QTYLabel" runat="server"
 Text='<%# Eval("MAX_INVENTORY_QTY") %>' />
<br />
경험치:
<asp:Label ID="EXPERIENCELabel" runat="server" Text='<%# Eval("EXPERIENCE") %>' />
<asp:Label ID="MODEL_IDLabel" runat="server" Text='<%# Eval("MODEL_ID") %>' Visible="FALSE" />
<asp:Label ID="SERVER_NOLabel" runat="server" Text='<%# Eval("SERVER_NO") %>' Visible="FALSE" />
<asp:Label ID="ACCOUNT_IDLabel" runat="server" Text='<%# Eval("ACCOUNT_ID") %>' Visible="FALSE" />
<br />
타이틀:
<asp:Label ID="TITLE_NAMELabel" runat="server" Text='<%# Eval("TITLE_NAME") %>' />
</ItemTemplate>
<ItemStyle HorizontalAlign="Right"></ItemStyle>
</asp:DataList>
    <asp:Button ID="btnInven1" runat="server"
 Text="캐디백" onclick="btnCaddie_Click" />
&nbsp;<asp:Button ID="btnInven" runat="server"
 Text="인벤토리" onclick="btnInven_Click" />
&nbsp;<asp:Button ID="btnInven0" runat="server"
 Text="캐릭터" onclick="btnInven0_Click" />
&nbsp;<asp:Button ID="btnGuildInfo" runat="server" onclick="btnGuildInfo_Click"
 Text="길드정보" />
&nbsp;<asp:Button ID="btnPark" runat="server" onclick="btnShop_Click"
 Text="상점가기" />
&nbsp;<asp:Button ID="btnPark0" runat="server" onclick="btnPark0_Click"
 Text="벤치가기" />
<br />
    <asp:DataList ID="DataListFindServerName" runat="server" 
        DataKeyField="SERVER_NO" DataSourceID="SqlDataSource2" Height="20px" 
        RepeatLayout="Flow" Visible="False" Width="112px">
        <ItemTemplate>
            SERVER_NAME:
            <asp:Label ID="SERVER_NAMELabel" runat="server" 
                Text='<%# Eval("SERVER_NAME") %>' />
            <br />
            SERVER_NO:
            <asp:Label ID="SERVER_NOLabel" runat="server" Text='<%# Eval("SERVER_NO") %>' />
            <br />
            <br />
        </ItemTemplate>
    </asp:DataList>
    <asp:DataList ID="DataListFindChName" runat="server" DataKeyField="CHANNEL_NO" 
        DataSourceID="SqlDataSource3" Height="30px" RepeatLayout="Flow" Visible="False">
        <ItemTemplate>
            CHANNEL_NO:
            <asp:Label ID="CHANNEL_NOLabel" runat="server" 
                Text='<%# Eval("CHANNEL_NO") %>' />
            <br />
            CHANNEL_NAME:
            <asp:Label ID="CHANNEL_NAMELabel" runat="server" 
                Text='<%# Eval("CHANNEL_NAME") %>' />
            <br />
            SERVER_NO:
            <asp:Label ID="SERVER_NOLabel" runat="server" Text='<%# Eval("SERVER_NO") %>' />
            <br />
            <br />
        </ItemTemplate>
    </asp:DataList>
    <asp:SqlDataSource ID="SqlDataSource3" runat="server" 
        ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
        ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>" 
        SelectCommand="SELECT &quot;CHANNEL_NO&quot;, &quot;CHANNEL_NAME&quot;, &quot;SERVER_NO&quot; FROM &quot;CHANNEL&quot; WHERE ((&quot;SERVER_NO&quot; = :SERVER_NO) AND (&quot;CHANNEL_NO&quot; = :CHANNEL_NO))">
        <SelectParameters>
            <asp:SessionParameter Name="SERVER_NO" SessionField="SERVER" Type="Decimal" />
            <asp:SessionParameter Name="CHANNEL_NO" SessionField="Ch" Type="Decimal" />
        </SelectParameters>
    </asp:SqlDataSource>
    <asp:SqlDataSource ID="SqlDataSource2" runat="server" 
        ConnectionString="<%$ ConnectionStrings:ConnectionString %>" 
        ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>" 
        SelectCommand="SELECT * FROM &quot;SERVER&quot; WHERE (&quot;SERVER_NO&quot; = :SERVER_NO)">
        <SelectParameters>
            <asp:SessionParameter Name="SERVER_NO" SessionField="SERVER" Type="Decimal" />
        </SelectParameters>
    </asp:SqlDataSource>
</td>
</tr>

<tr>
<td>
    <font color="white" size="5px">내가 받은 쪽지</font><br />
<br />
<asp:GridView ID="gvMessage" runat="server" AllowPaging="True" 
        AutoGenerateColumns="False" CellPadding="4"
 DataKeyNames="MESSAGE_DATETIME,CHARACTER_NAME,SERVER_NO"
 DataSourceID="sqldsMessage"
 EmptyDataText="There are no data records to display." ForeColor="#333333"
 GridLines="None" HorizontalAlign="Center">
<RowStyle BackColor="#F7F6F3" ForeColor="#333333" />
<Columns>
    <asp:CommandField ShowDeleteButton="True" />
<asp:BoundField DataField="MESSAGE_DATETIME" HeaderText="MESSAGE_DATETIME"
 ReadOnly="True" SortExpression="MESSAGE_DATETIME" />
<asp:BoundField DataField="CONTENT" HeaderText="CONTENT"
 SortExpression="CONTENT" />
<asp:BoundField DataField="CHARACTER_NAME" HeaderText="CHARACTER_NAME"
 ReadOnly="True" SortExpression="CHARACTER_NAME" Visible="False" />
<asp:BoundField DataField="SERVER_NO" HeaderText="SERVER_NO" ReadOnly="True"
 SortExpression="SERVER_NO" Visible="False" />
</Columns>
<FooterStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
<PagerStyle BackColor="#284775" ForeColor="White" HorizontalAlign="Center" />
    <EmptyDataTemplate>
        <br />
        <font color="#ffff99">수신된 쪽지가 없습니다.</font><br />
        <br />
    </EmptyDataTemplate>
<SelectedRowStyle BackColor="#E2DED6" Font-Bold="True" ForeColor="#333333" />
<HeaderStyle BackColor="#5D7B9D" Font-Bold="True" ForeColor="White" />
<EditRowStyle BackColor="#999999" />
<AlternatingRowStyle BackColor="White" ForeColor="#284775" />
</asp:GridView>
<asp:SqlDataSource ID="sqldsMessage" runat="server"
 ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
 DeleteCommand="DELETE FROM &quot;MESSAGE&quot; WHERE &quot;MESSAGE_DATETIME&quot; = :MESSAGE_DATETIME AND &quot;CHARACTER_NAME&quot; = :CHARACTER_NAME AND &quot;SERVER_NO&quot; = :SERVER_NO"
 InsertCommand="INSERT INTO &quot;MESSAGE&quot; (&quot;CONTENT&quot;, &quot;MESSAGE_DATETIME&quot;, &quot;CHARACTER_NAME&quot;, &quot;SERVER_NO&quot;) VALUES (:CONTENT, :MESSAGE_DATETIME, :CHARACTER_NAME, :SERVER_NO)"
 ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>"
 SelectCommand="SELECT CONTENT, MESSAGE_DATETIME, CHARACTER_NAME, SERVER_NO FROM MESSAGE WHERE (SERVER_NO = :SERVER_NO) AND (CHARACTER_NAME = :CHARACTER_NAME) ORDER BY MESSAGE_DATETIME DESC"
 UpdateCommand="UPDATE &quot;MESSAGE&quot; SET &quot;CONTENT&quot; = :CONTENT WHERE &quot;MESSAGE_DATETIME&quot; = :MESSAGE_DATETIME AND &quot;CHARACTER_NAME&quot; = :CHARACTER_NAME AND &quot;SERVER_NO&quot; = :SERVER_NO">
<SelectParameters>
<asp:SessionParameter Name="SERVER_NO" SessionField="SERVER" />
<asp:SessionParameter Name="CHARACTER_NAME" SessionField="CHARACTER_NAME" />
</SelectParameters>
<DeleteParameters>
<asp:Parameter Name="MESSAGE_DATETIME" Type="DateTime" />
<asp:Parameter Name="CHARACTER_NAME" Type="String" />
<asp:Parameter Name="SERVER_NO" Type="Decimal" />
</DeleteParameters>
<InsertParameters>
<asp:Parameter Name="CONTENT" Type="String" />
<asp:Parameter Name="MESSAGE_DATETIME" Type="DateTime" />
<asp:Parameter Name="CHARACTER_NAME" Type="String" />
<asp:Parameter Name="SERVER_NO" Type="Decimal" />
</InsertParameters>
<UpdateParameters>
<asp:Parameter Name="CONTENT" Type="String" />
<asp:Parameter Name="MESSAGE_DATETIME" Type="DateTime" />
<asp:Parameter Name="CHARACTER_NAME" Type="String" />
<asp:Parameter Name="SERVER_NO" Type="Decimal" />
</UpdateParameters>
</asp:SqlDataSource>
<br />
</td>
<td colspan="2">
<font color="white" size="5px">쪽지 보내기<br />
</font>
<asp:GridView ID="gvChannelEntrance" runat="server" AutoGenerateColumns="False"
 CellPadding="4"
 DataSourceID="sqldsChannelEntrance" EmptyDataText="표시할 데이터 레코드가 없습니다."
 ForeColor="#333333" GridLines="None" AllowPaging="True"
 AllowSorting="True" DataKeyNames="CHARACTER_NAME"
 onselectedindexchanged="gvChannelEntrance_SelectedIndexChanged" HorizontalAlign="Center">
<RowStyle BackColor="#EFF3FB" />
<Columns>
<asp:CommandField ShowSelectButton="True" SelectText="쪽지" />
<asp:BoundField DataField="CHARACTER_NAME" HeaderText="현재 접속자"
 SortExpression="CHARACTER_NAME"
ItemStyle-HorizontalAlign="Right" >
<ItemStyle HorizontalAlign="Right"></ItemStyle>
    </asp:BoundField>
</Columns>
<FooterStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<PagerStyle BackColor="#2461BF" ForeColor="White" HorizontalAlign="Center" />
<EmptyDataTemplate>
<br />
<font color="#ffff99" 접속중인 캐릭터가 없습니다.<br />
</EmptyDataTemplate>
<SelectedRowStyle BackColor="#D1DDF1" Font-Bold="True" ForeColor="#333333" />
<HeaderStyle BackColor="#507CD1" Font-Bold="True" ForeColor="White" />
<EditRowStyle BackColor="#2461BF" />
<AlternatingRowStyle BackColor="White" />
</asp:GridView>
<br />
<asp:SqlDataSource ID="sqldsChannelEntrance" runat="server"
 ConnectionString="<%$ ConnectionStrings:ConnectionString %>"
 ProviderName="<%$ ConnectionStrings:ConnectionString.ProviderName %>"
 SelectCommand="SELECT CHARACTER_NAME FROM CHANNEL_ENTRANCE_STATUS WHERE (CHANNEL_NO = :CHANNEL_NO) AND (SERVER_NO = :server)"
 OldValuesParameterFormatString="original_{0}">
<SelectParameters>
<asp:SessionParameter Name="CHANNEL_NO" SessionField="Ch" Type="Decimal" />
    <asp:SessionParameter Name="server" SessionField="SERVER" />
</SelectParameters>
</asp:SqlDataSource>
<br />
<asp:Label ID="lblMember" runat="server" Text="선택된 멤버가 없습니다." Visible="false" ForeColor="#ffff99"></asp:Label>
<br />
<br />
<asp:Label ID="Label9" runat="server" Height="20px" Text="메시지 : "></asp:Label>
&nbsp;<asp:TextBox ID="txtMessage" runat="server" Width="201px" Height="21px"></asp:TextBox>
&nbsp;<asp:Button ID="btnMessage" runat="server" onclick="btnMessage_Click" Text="쪽지 보내기"
 style="margin-top: 0px" /></td>
</tr>
</table>
</div>
</form>
</body>
</html>
